﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="ManageLogs.aspx.cs" Inherits="CocisWeb.admin.ManageLogs" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
<title></title>
<link href="../css/cont.css" rel="stylesheet" type="text/css" />
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<script language="javascript" type="text/javascript" src="../datepicker/WdatePicker.js"></script>
<script type="text/javascript">
    function SelectAll(chkbox) {
        var theBox = chkbox;
        xState = theBox.checked;
        elem = theBox.form.elements;
        for (i = 0; i < elem.length; i++)
            if (elem[i].type == "checkbox" && elem[i].id != theBox.id) {
            if (elem[i].checked != xState)
                elem[i].click();
        }
    }
</script>
    
</head>
<body style="padding-left:5px;padding-right:5px;background-image:url(../images/bg.gif);	background-repeat:repeat-x;">
 <form id="form1" runat="server">
 
  <table style="height:100%; width:100%;" border="0px" cellpadding="0px" cellspacing="0px">
  <tr style="background-image: url(../images/bg_header.gif); background-repeat: repeat-x; height:47px">
  <td style="width:10px;background-image: url(../images/main_hl.gif);"></td>
  <td>
     <span style="float: left; background-image: url(../images/main_hl2.gif); width: 15px; background-repeat: no-repeat; height: 47px"></span>
      <span style="padding-right: 10px; padding-left: 10px; float: left; background-image: url(../images/main_hb.gif); line-height:47px; color: white; background-repeat: repeat-x; height: 47px; text-align: center;">
      Log Management
      </span>
      <span style="float: left; background-image: url(../images/main_hr.gif); width: 60px; background-repeat: no-repeat; height: 47px"></span>
  </td>
  <td style="background-image: url(../images/main_hr2.gif);width:10px"></td>
  </tr>
  <tr>
  <td style="background-image: url(../images/main_ls.gif)"></td>
  <td style="padding-right: 10px; padding-left: 10px; padding-bottom: 10px; color: #566984; padding-top:10px; background-color: white;">
      <br />
        &nbsp;UserName：<asp:TextBox ID="txtUserName" runat="server" Width="87px"></asp:TextBox>&nbsp;LogType：<asp:DropDownList 
          ID="ddlLogType" runat="server">
          <asp:ListItem Value="1">Login Logs</asp:ListItem>
          <asp:ListItem Value="2">Operate Logs</asp:ListItem>
          <asp:ListItem Value="0" Selected="True">ALL</asp:ListItem>
      </asp:DropDownList>
      &nbsp;StartDate：<asp:TextBox 
          ID="txtDateStart"  runat="server" Width="90px" class="Wdate" onFocus="WdatePicker({lang:'en'})"></asp:TextBox>&nbsp;EndDate：<asp:TextBox 
          ID="txtDateEnd" runat="server" Width="90px" class="Wdate" onFocus="WdatePicker({lang:'en'})"></asp:TextBox>&nbsp;<asp:Button 
          ID="btnSearch" runat="server"
            Text="SEARCH" CssClass="button_normal" onclick="btnSearch_Click" />     

                &nbsp;<asp:Button ID="btnDelete" runat="server"
            Text="DELETE" CssClass="button_normal" onclick="btnDelete_Click" />     

                <br />
      <br />

        <asp:GridView ID="gvRole" runat="server" AutoGenerateColumns="False"
            Height="30px" PageSize="25" AllowPaging="True" 
          onpageindexchanging="gvRole_PageIndexChanging" style="text-align: left" 
           >
            <Columns>
                <asp:TemplateField HeaderText="Select">
                   <HeaderTemplate>
                                 <input id="chkHeader" onclick="SelectAll(this)" type="checkbox" />
                             </HeaderTemplate>
                    <ItemTemplate>
                        <asp:CheckBox ID="CheckBox1" runat="server" />
                    </ItemTemplate>
                    <ItemStyle Width="40px" />
                </asp:TemplateField>
                <asp:BoundField DataField="logid" HeaderText="No" >
                    <ItemStyle Width="35px" />
                </asp:BoundField>
                <asp:BoundField DataField="Date" HeaderText="Date">
                    <ItemStyle Width="120px" />
                </asp:BoundField>
                <asp:BoundField DataField="Loginuser" HeaderText="UserName" ReadOnly="True">
                    <ItemStyle Width="70px" />
                </asp:BoundField>
                <asp:BoundField DataField="Ip" HeaderText="ComputerIP">
                    <ItemStyle Width="100px" />
                </asp:BoundField>
                <asp:BoundField DataField="events" HeaderText="Event">
                    <ItemStyle Width="400px" />
                </asp:BoundField>
            </Columns>
            <EmptyDataTemplate>
                <div>
                    ………………</div>
            </EmptyDataTemplate>
            <HeaderStyle CssClass="datagrid_headrstyle_normal" />
            <PagerSettings FirstPageText="FirstPage" LastPageText="EndPage" NextPageText="NextPage" 
                Mode="NextPreviousFirstLast" PreviousPageText="PreviousPage" 
                FirstPageImageUrl="~/images/main_54.gif" 
                LastPageImageUrl="~/images/main_60.gif" NextPageImageUrl="~/images/main_58.gif" 
                PreviousPageImageUrl="~/images/main_56.gif" />
            <FooterStyle CssClass="datagrid_footerstyle_normal" Height="20px" />
            <RowStyle HorizontalAlign="Left" Height="19px" />
            
        </asp:GridView>
      <br />
      <br />
      
      <br />
      </td>
  <td style="background-image: url(../images/main_rs.gif)"></td>
  </tr>
  </table>
  </form>
</body>
</html>
